import React,{forwardRef,useImperativeHandle} from 'react'

function testUseRef(props:any,ref:any) {
    useImperativeHandle(ref,()=>({
        click:function (){
            console.log(`我是子组件 我又自己的名字，${'123456789'}`)
        },
        name:'子组件才是大爷啊'
    }))
  return (
    <div ref={ref}>我是子组件啊 大哥</div>
  )
}
const TestUseRef = forwardRef(testUseRef)
export default TestUseRef
